﻿Partial Public Class LmsInit
    Inherits System.Web.UI.Page

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If Request.UrlReferrer.AbsoluteUri.IndexOf("InitLMS.aspx") >= 0 Then

            Dim result As String

            result = Mysoft.Map.LMS.Initialization.CheckLmsDBConnect()
            If result = "<xml result=""true"" ></xml>" Then
                Dim isInit As Boolean = Mysoft.Map.LMS.Initialization.IsInitLms()
                If Not isInit Then
                    result = Mysoft.Map.LMS.Initialization.InitLms()
                End If
            End If

            Response.ContentType = "text/HTML"
            Response.Clear()
            Response.Write(result)
            Response.End()

        End If
    End Sub

End Class